package singleton;

/**
 * 静态内部类方式,线程安全
 */
public class SingleTon6 {

    private static class StaticSingleTon{
        private static final SingleTon6 instance = new SingleTon6();
    }

    public static SingleTon6 getInstance(){
        return StaticSingleTon.instance;
    }
}
